﻿@{
    ViewBag.Title = "Edit Profile";
}

@model DiaosFix.Web.MVC.Models.EditProfileModel

<h2>Edit Profile of @User.Identity.Name</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm())
{
    @Html.ValidationSummary(true, "Input data is not correct.")
    <fieldset>
        <legend>User Detail Information</legend>
        <div class="editor-label">
            @Html.LabelFor(m => m.RealName)
        </div>
        <div class="editor-field">
            @Html.TextBoxFor(m => m.RealName, new { @Value = ViewBag.RealName })
            @Html.ValidationMessageFor(m => m.RealName)
        </div>

        <div class="editor-label">
            @Html.LabelFor(m => m.Address)
        </div>
        <div class="editor-field">
            @Html.TextBoxFor(m => m.Address, new { @Value = ViewBag.Address })
            @Html.ValidationMessageFor(m => m.Address)
        </div>

        <div class="editor-label">
            @Html.LabelFor(m => m.ContactNumber)
        </div>
        <div class="editor-field">
            @Html.TextBoxFor(m => m.ContactNumber, new { @Value = ViewBag.ContactNumber })
            @Html.ValidationMessageFor(m => m.ContactNumber)
        </div>

        <div class="editor-label">
            @Html.LabelFor(m => m.Email)
        </div>
        <div class="editor-field">
            @Html.TextBoxFor(m => m.Email, new { @Value = ViewBag.Email })
            @Html.ValidationMessageFor(m => m.Email)
        </div>

        <p>
            <input type="submit" value="Confirm" />
        </p>
    </fieldset>
}